1. Field of the Invention
The invention relates to a computer system which includes a plurality of memory banks and, in particular, to a computer system which is capable of performing a high-speed computation, such as a parallel computer or a computer having a vector processor.
2. Description of the Related Art
To achieve high-speed processing in a computer, a technology including a vector operation or a parallel operation has been used.
In a large-scale computer such as a super computer, plenty of time is used to repeat similar operation which consists of predetermined procedures on each data, for example, a matrix calculation or operations in Do-loop statements in Fortran language.
In the vector processor, to achieve the repetition in a high-speed, matrices and data are gathered into one or more vectors and computation of the vectors are performed in a single instruction. Thereby, it is not required to perform calculation for each element in the matrix. As a result, the vector processor can perform the calculation in a high-speed. The high-speed calculation of the matrix is done by dividing instructions about the elements into a plurality of phases such as “calling of instruction”, “interpretation of instruction”, and “address computation”, and performing each phase in parallel under a pipeline control.
In the parallel operation, each of a plurality of processors (computers) is used to perform processing of data corresponding to the processor in parallel and consequently, whole process are performed in a high-speed.
Also the data which are thus gathered in the vector processor and assigned to the corresponding processor, may often individually processed in its processing. Such the individual process occurs, for example, by a conditional operation. The conditional operation may be set by an “IF” statement in a Do-loop in Fortran language.
For example, there may be a case in a loop where after elements in an array are loaded via indirect referencing, predetermined computation is executed on the elements, and the computation results are stored into each original address where the element is originally stored. In particular, the above aspect of operation often occurs in a scientific computation of finite-element method and molecular dynamics.
In a loop including such the operation, it is required to guarantee that a plurality of data under vectorization or parallelization are not stored into the same location. If the operation in the loop is performed via forced vectorization or parallelization without the guarantee, an incorrect computation result may be obtained.
Also, in a process of classifying data in a group into predetermined new groups one by one, it is difficult to perform the classifying process via vectorization or parallelization. That is, in a loop of the classifying process, each of counters corresponds to a new group and when it is determined that data belongs to one of the new group, the counter of the new group is updated. If the classifying process is performed via forced vectorization or parallelization, consistency of updating counters may be not maintained.
In a conventional technique, if such the operation in a loop is performed via vectorization or parallelization, a programmer must avoid duplication of location where updated data are stored or duplication of updating of a counter, by improving method of storing data or changing an order of computations.
Therefore, there are problems to be solved in a conventional computer system.
First, it is a burden for a programmer to make a special program to avoid duplication of a location where updated data are stored or duplication of updating a counter, in a conventional computer system.
Second, it is difficult to amend programs which have been accumulated to adapt to a vector computer or a shared memory parallel computer, since it is required to drastically amend the programs to adapt to them.
Further, some applications can not be performed in a high-speed, since a preparation process for parallel processing or vector processing of the applications can not be performed via vectorization or parallelization.